/**
    算法描述：记录每个字母出现的频次即可，如何做记录？只需要存在数组中即可
    解决所需数据结构+算法：数组
**/
#include<iostream>
#include<cstring>
using namespace std;

bool isPrime(int x) {
    if(x < 2)   return false;
    for(int i=2; i*i<=x; i++)
        if(x % i == 0)  return false;
    return true;
}

int main() {
    int a[110], maxx = 0, minn = 0x3fff;
    memset(a, 0, sizeof(a));
    string str;
    cin >> str;
    for(int i=0; i<str.size(); i++) {
        a[str[i] - 'a']++;
    }
    for(int i=0; i<26; i++) {
        if(!a[i])   continue;
        if(a[i] > maxx) maxx = a[i];
        if(a[i] < minn) minn = a[i];
    }
    if(isPrime(maxx - minn))    cout << "Lucky Word" << endl << maxx - minn << endl;
    else cout << "No Answer" << endl << 0 << endl;
    return 0;
}